package com.wushi.lenovo.asia5b.app_di.profile.mvpview;

import com.wushi.lenovo.asia5b.app_di.other.presenter.CodePresenter;
import com.wushi.lenovo.asia5b.app_http.ApiService;
import com.wushi.lenovo.asia5b.app_model.other.UserInfo;

import javax.inject.Inject;


/**
 * Created by zhangyuncai on 2019/3/1.
 */
public class FirstPayPassActivityPresenter extends CodePresenter<FirstPayPassActivityView> {

    ApiService apiService;

    @Inject
    public FirstPayPassActivityPresenter(ApiService apiService) {
        super(apiService);
        this.apiService = apiService;
    }

    public void changePass(String pass, String code) {
        baseSubscribe(apiService.changePaymentPassWord(UserInfo.getMemberId(), pass, code), resultModel -> {
            getView().changePassResult(resultModel);
        });
    }
}